package com.dss.auto_deploy.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
/**
* @Description:配置自动触发更新的项目/分支实体类
* @author dongshoushan
* @date 2022-10-22 14:13:37
*/
@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
@TableName("adm_project_auto_config")
@ApiModel(description = "配置自动触发更新的项目/分支")
public class AdmProjectAutoConfig {

    /**
    * ID主键
    */
    @ApiModelProperty(value = "ID主键")
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
    * 项目id
    */
    @ApiModelProperty(value = "项目id")
    private Long projectId;

    /**
    * 分支名称
    */
    @ApiModelProperty(value = "分支名称")
    private String branch;

    /**
    * 命名空间id
    */
    @ApiModelProperty(value = "命名空间id")
    private Long namespaceId;

    /**
     * 0关闭自动部署 1开启自动部署 2只存储镜像
     */
    @ApiModelProperty(value = "0关闭自动部署 1开启自动部署 2只存储镜像")
    private Integer state;

    /**
    * 更新时间
    */
    @ApiModelProperty(value = "更新时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;

}
